package com.cunshe.service;

import com.cunshe.dao.CompanyProfileDao;
import com.cunshe.domain.CompanyProfile;
import org.springframework.beans.factory.annotation.Autowired;
import org.springframework.stereotype.Service;
import org.springframework.transaction.annotation.Transactional;

import java.util.Date;
import java.util.List;

/**
 * 公司简介
 * @author xiao
 */
@Service
public class CompanyProfileService {

    @Autowired
    private CompanyProfileDao companyProfileDao;

    /** 修改 */
    @Transactional(rollbackFor = Exception.class)
    public int update(CompanyProfile record) {
        record.setUpdatetime(new Date());
        return companyProfileDao.update(record);
    }

    /** 查询列表 */
    public CompanyProfile get() {
        return companyProfileDao.get();
    }

}